package com.wjk.kylin.id.server.exception;


import lombok.Data;

/**
 * 自定义异常
 */
@Data
public class BaseException extends RuntimeException {

	private BaseError error;
	protected Throwable throwable;

	public BaseException(BaseError error) {
		this.error = error;
	}

	public BaseException(String message) {
		this.error = new BaseError(message);
	}

	public BaseException(String message, Throwable e) {
		this.error = new BaseError(message);
		this.throwable = e;
	}
}
